﻿using Bll;
using Model;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

namespace Myproject.BSM.PcWeb.PcBase
{
    public partial class ContactEdit : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            string id = Request.QueryString["id"];
            if (!string.IsNullOrEmpty(id))
            {
                pc_base_ContactEdit_ContactID.Value = id;
                ContactModel model = new ContactBLL().GetModel(Int32.Parse(id));
                pc_base_ContactEdit_show.Value = model.Show.ToString();
                pc_base_ContactEdit_name.Value = model.Name;
                pc_base_ContactEdit_ename.Value = model.EName.ToString();
                pc_base_ContactEdit_post.Value = model.Post.ToString();
                pc_base_ContactEdit_epost.Value = model.EPost.ToString();
                pc_base_ContactEdit_phone.Value = model.MobilePhone.ToString();
                pc_base_ContactEdit_tel.Value = model.OfficePhone.ToString();
                pc_base_ContactEdit_email.Value = model.Email.ToString();
                pc_base_ContactEdit_rank.Value = model.Rank.ToString();
            }
        }
    }
}